package com.lishe.lishe.lishe.module.excitation.bean;

import android.os.Parcel;
import android.os.Parcelable;

import com.alibaba.fastjson.JSON;
import com.google.gson.annotations.SerializedName;

import java.lang.reflect.Array;
import java.util.ArrayList;
import java.util.List;

/**
 * Created by DELL on 2017/10/31.
 */

public class AchievementObject implements Parcelable{

    @SerializedName("achieveName")
    private String achieveName;//		成就名称

    @SerializedName("achieveImg")
    private String achieveImg;//		成就图片地址

    @SerializedName("comId")
    private String comId;//		企业ID

    @SerializedName("userId")
    private String userId;//		用户ID

    @SerializedName("achieveId")
    private String achieveId;//		成就ID

    @SerializedName("achievedTime")
    private long achievedTime=0;//		成就获取时间

    @SerializedName("achieveType")
    private String achieveType;//		成就类型

    @SerializedName("achieveReward")
    private String achieveReward;//		成就奖赏

    @SerializedName("achieveDesc")
    private String achieveDesc;//		成就描述

    @SerializedName("admireCount")
    private int admireCount;//		达成成就需要鼓励次数

    @SerializedName("hadCount")
    private int hadCount;//	已获得鼓励数

    @SerializedName("achievementVoList")
    private List<AchievementVoListObject> achievementVoLists;//		获取行为成就/目标成就时所需要对应行为的成就列表

    @SerializedName("receivedRewardFlag")
    private int receivedRewardFlag;//		领取奖赏标识：0未领取1已领取

    @SerializedName("receivedRewardTime")
    private String receivedRewardTime;//		领取时间

    public AchievementObject(){

    }

    protected AchievementObject(Parcel in) {
        achieveName = in.readString();
        achieveImg = in.readString();
        comId = in.readString();
        userId = in.readString();
        achieveId = in.readString();
        achievedTime = in.readLong();
        achieveType = in.readString();
        achieveReward = in.readString();
        achieveDesc = in.readString();
        admireCount = in.readInt();
        hadCount = in.readInt();
        receivedRewardFlag = in.readInt();
        receivedRewardTime = in.readString();
    }

    public static final Creator<AchievementObject> CREATOR = new Creator<AchievementObject>() {
        @Override
        public AchievementObject createFromParcel(Parcel in) {
            return new AchievementObject(in);
        }

        @Override
        public AchievementObject[] newArray(int size) {
            return new AchievementObject[size];
        }
    };

    public String getAchieveName() {
        return achieveName;
    }

    public void setAchieveName(String achieveName) {
        this.achieveName = achieveName;
    }

    public String getAchieveImg() {
        return achieveImg;
    }

    public void setAchieveImg(String achieveImg) {
        this.achieveImg = achieveImg;
    }

    public String getComId() {
        return comId;
    }

    public void setComId(String comId) {
        this.comId = comId;
    }

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public String getAchieveId() {
        return achieveId;
    }

    public void setAchieveId(String achieveId) {
        this.achieveId = achieveId;
    }

    public long getAchievedTime() {
        return achievedTime;
    }

    public void setAchievedTime(long achievedTime) {
        this.achievedTime = achievedTime;
    }

    public String getAchieveType() {
        return achieveType;
    }

    public void setAchieveType(String achieveType) {
        this.achieveType = achieveType;
    }

    public String getAchieveReward() {
        return achieveReward;
    }

    public void setAchieveReward(String achieveReward) {
        this.achieveReward = achieveReward;
    }

    public String getAchieveDesc() {
        return achieveDesc;
    }

    public void setAchieveDesc(String achieveDesc) {
        this.achieveDesc = achieveDesc;
    }

    public int getAdmireCount() {
        return admireCount;
    }

    public void setAdmireCount(int admireCount) {
        this.admireCount = admireCount;
    }

    public int getHadCount() {
        return hadCount;
    }

    public void setHadCount(int hadCount) {
        this.hadCount = hadCount;
    }

    public List<AchievementVoListObject> getAchievementVoLists() {
        return achievementVoLists;
    }

    public void setAchievementVoLists(ArrayList<AchievementVoListObject> achievementVoLists) {
        this.achievementVoLists = achievementVoLists;
    }

    public int getReceivedRewardFlag() {
        return receivedRewardFlag;
    }

    public void setReceivedRewardFlag(int receivedRewardFlag) {
        this.receivedRewardFlag = receivedRewardFlag;
    }

    public String getReceivedRewardTime() {
        return receivedRewardTime;
    }

    public void setReceivedRewardTime(String receivedRewardTime) {
        this.receivedRewardTime = receivedRewardTime;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(achieveName);
        dest.writeString(achieveImg);
        dest.writeString(comId);
        dest.writeString(userId);
        dest.writeString(achieveId);
        dest.writeLong(achievedTime);
        dest.writeString(achieveType);
        dest.writeString(achieveReward);
        dest.writeString(achieveDesc);
        dest.writeInt(admireCount);
        dest.writeInt(hadCount);
        dest.writeInt(receivedRewardFlag);
        dest.writeString(receivedRewardTime);
    }
}
